<?php

namespace maotool\core\request;

use JsonSerializable;

class PageParam extends Param implements JsonSerializable
{

    /**
     * 每页显示条数，默认 10
     * @var int
     */
    private $pageSize = 10;

    /**
     * 当前页
     * @var int
     */
    private $pageNo = 1;

    /**
     * 当前页
     * @var int
     */
    private $pageNum = 1;

    /**
     * 请求参数
     * @var object
     */
    private $param;

    /**
     * 请求备注
     * @var string
     */
    private $remark;

    /**
     * @return int
     */
    public function getPageSize()
    {
        return $this->pageSize;
    }

    /**
     * @param int $pageSize
     */
    public function setPageSize($pageSize)
    {
        $this->pageSize = $pageSize;
    }

    /**
     * @return int
     */
    public function getPageNo()
    {
        return $this->pageNo;
    }

    /**
     * @param int $pageNo
     */
    public function setPageNo($pageNo)
    {
        $this->pageNo = $pageNo;
        $this->pageNum = $pageNo;
    }

    /**
     * @return int
     */
    public function getPageNum()
    {
        return $this->pageNum;
    }

    /**
     * @param int $pageNum
     */
    public function setPageNum($pageNum)
    {
        $this->pageNo = $pageNum;
        $this->pageNum = $pageNum;
    }

    /**
     * @return object
     */
    public function getParam()
    {
        return $this->param;
    }

    /**
     * @param object $param
     */
    public function setParam($param)
    {
        $this->param = $param;
    }


    /**
     * @return string
     */
    public function getRemark()
    {
        return $this->remark;
    }

    /**
     * @param string $remark
     */
    public function setRemark($remark)
    {
        $this->remark = $remark;
    }

    public function jsonSerialize()
    {
        return [
            "pageSize" => $this->pageSize,
            "pageNo" => $this->pageNo,
            "pageNum" => $this->pageNum,
            "param" => $this->param,
        ];
    }

}